import React, { Component } from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';

import './index.less';
class Progress extends Component {
  render() {
    let {progress, className} = this.props;
    progress = progress ? progress : 0;
    return (
      <div className={classnames('component-progress-container', className)}>
        <div className="component-progress-complete" style={{width: `${progress}%`, height: `100%`}}></div>
      </div>
    );
  }
}

Progress.propTypes = {
  progress: PropTypes.number
};

export default Progress;